package com.cqcomponents.components;

import com.cqcomponents.annotations.JcrPropertyInjection;

public class Column extends BaseComponent {

	private int offset = -1;
	private int span = -1;

	@JcrPropertyInjection
	public void setOffset(int offset) {
		this.offset = offset;
	}

	public int getOffset() {
		return this.offset;
	}

	public int getSpan() {
		return this.span;
	}

	@JcrPropertyInjection
	public void setSpan(int span) {
		this.span = span;
	}

	@Override
	public String toString() {
		return "Column={span:" + this.span + ",offset:" + this.offset + "}";
	}

	@Override
	public boolean getHasContent() {
		return offset != -1 && span != -1;
	}
}
